package kr.or.javacafe.app01.repository;

import java.util.List;

import kr.or.javacafe.app01.domain.CodeMaster;
import kr.or.javacafe.app01.domain.CodeSlave;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.orm.ibatis.SqlMapClientTemplate;
import org.springframework.stereotype.Repository;

@Repository
public class CodeMasterRepository {

	@Autowired
	private SqlMapClientTemplate sqlMapClientTemplate;
	
	
	
	public List<CodeMaster> selectCodeMasterList() {
		return sqlMapClientTemplate.queryForList("App01Map.selectCodeMasterList");
	}
	
	public List<CodeSlave> selectCodeSlaveList(String mcode) {
		return sqlMapClientTemplate.queryForList("App01Map.selectCodeSlaveList", mcode);
	}
}
